const express = require('express')
const router = express.Router()
//到户用户路由对应的模块

const user_handler = require('../router_handler/user')

const expressJoi = require('@escook/express-joi')

const { reg_login_ruls } = require('../ValidationRules/user')
// 注册新用户
router.post('/reguser',expressJoi(reg_login_ruls), user_handler.reguser)
// 登录
router.post('/login',expressJoi(reg_login_ruls), user_handler.login)

module.exports = router
